Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New language translation: Urdu #329

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

asfand-dev
Copy link

Description

Added Urdu language support and localization

Related Issues

  • Issue #<issue_number>

Checklist

  • I have read and followed the Contributing Guidelines.
  • I have added necessary tests.
  • The project builds and runs without issues.

@asfand-dev
Copy link
Author

Here are the screenshots:

Screenshot 2024-12-17 at 9 20 30 AM Screenshot 2024-12-17 at 9 20 37 AM

@itz-rj-here
Copy link
Collaborator

@asfand-dev I appreciate your thoughtful adjustments. It would be very appreciated if you could include the language detail in the readme file too. Thanks.
image

Copy link
Collaborator

@itz-rj-here itz-rj-here left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add the language name in the readme file too.

@prem-k-r
Copy link
Collaborator

prem-k-r commented Dec 17, 2024

Here are the screenshots:

Screenshot 2024-12-17 at 9 20 30 AM Screenshot 2024-12-17 at 9 20 37 AM

can you please provide ss for digital clock too

you can add translation for google apps and to-do list too
there seems some issue with Feels-like unit and humidity..

btw for decimal separator isn't dot or ۔ (Arabic decimal separator) is used? I could be wrong

@itz-rj-here
Copy link
Collaborator

Here are the screenshots:
Screenshot 2024-12-17 at 9 20 30 AM Screenshot 2024-12-17 at 9 20 37 AM

can you please provide ss for digital clock too

you can add translation for google apps and to-do list too there seems some issue with Feels-like unit..

btw for decimal separator isn't dot or ۔ (Arabic decimal separator) is used? I could be wrong

Simply we write everything from left to right. But in arabic or urdu, we have to write from right to left. thats all others are the same as usual.

@prem-k-r
Copy link
Collaborator

I know bro

@itz-rj-here
Copy link
Collaborator

I know bro

Good.

@prem-k-r
Copy link
Collaborator

prem-k-r commented Dec 17, 2024

I know bro

Good.

Humidity is like 76 ytidimuH%
It probably should be 76% ytidimuH
Similarly for feels like

@itz-rj-here
Copy link
Collaborator

I know bro

Good.

Humidity is like 76 ytidimuH% It probably should be 76% ytidimuH Similarly for feels like

Uhhh. I accidently forgot about the numberings in arabic bruh

@XengShi
Copy link
Owner

XengShi commented Dec 17, 2024

I know bro

Good.

Humidity is like 76 ytidimuH%
It probably should be 76% ytidimuH
Similarly for feels like

Bro literally wrote urdu using english letters
'ytidimuH' 🙃

languages.js Show resolved Hide resolved
languages.js Show resolved Hide resolved
languages.js Show resolved Hide resolved
@@ -1822,6 +1950,7 @@ const menuWidths = {
idn: '415px',
tr: '418px',
fr: '490px',
ur: '450px',
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not needed, please remove

@@ -1835,7 +1964,7 @@ function localizeNumbers(text, language) {
const map = numberMappings[language]; // Get the numeral map for the current language

// Define languages that use a comma as the decimal separator instead of a dot
const specialDecimalLanguages = ['cs', 'it', 'pt', 'ru', 'tr', 'vi', 'uz', 'es', 'ko', 'idn', 'fr']; // Add more languages here as needed
const specialDecimalLanguages = ['cs', 'it', 'pt', 'ru', 'tr', 'vi', 'uz', 'es', 'ko', 'idn', 'fr', 'ur']; // Add more languages here as needed
Copy link
Collaborator

@prem-k-r prem-k-r Dec 18, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please confirm for decimal separator (28.6), comma is used (=28,6)
isn't dot or ۔ (Arabic decimal separator) used?

@@ -495,6 +495,7 @@ function updateDate() {
vi: `${dayName}, Ngày ${dayOfMonth} ${monthName}`,
idn: `${dayName}, ${dayOfMonth} ${monthName}`,
fr: `${dayName.substring(0, 3)}, ${dayOfMonth} ${monthName.substring(0, 3)}`, //Jeudi, 5 avril
ur: `${dayName}, ${dayOfMonth} ${monthName}`,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

urdu version comma ، will be used, no?

@@ -630,6 +631,7 @@ function updatedigiClock() {
vi: `${dayOfMonth} ${dayName}`,
idn: `${dayOfMonth} ${dayName}`,
fr: `${dayName} ${dayOfMonth}`, //Mardi 11
ur: `${dayName}, ${dayOfMonth}`,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

also here ،

Copy link
Collaborator

@prem-k-r prem-k-r left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For Humidity and Feels we have to change in the code.
See if you can add else we will do it.. also adding Urdu in Readme.md

@prem-k-r
Copy link
Collaborator

@asfand-dev

@XengShi
Copy link
Owner

XengShi commented Dec 18, 2024

Thank you for the contribution! Could you please consider changing the font for Urdu? You can use fonts from fonts.google.com as the current one looks a bit unappealing.

And, please change محسوس 23.2°C to 23.2°C محسوس so that the temperature appears before the unit.
and also 12 گھنٹے کا فارمیٹ to گھنٹے کا فارمیٹ‎ 12

Screenshot From 2024-12-18 13-20-56
Screenshot From 2024-12-18 13-20-42

Example of new font:
Screenshot From 2024-12-18 13-28-18
Screenshot From 2024-12-18 13-27-52

@prem-k-r
Copy link
Collaborator

for me, it is showing in this font
image

@XengShi
Copy link
Owner

XengShi commented Dec 18, 2024

for me, it is showing in this font
image

I guess it is using the font from the system, and I have the ugly one

@prem-k-r
Copy link
Collaborator

hi @asfand-dev, please fix conflicts

@itz-rj-here itz-rj-here added changes required PR requires updates based on review feedback i18n / l10n Related to Globalization labels Jan 1, 2025
@prem-k-r prem-k-r marked this pull request as draft January 21, 2025 05:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changes required PR requires updates based on review feedback i18n / l10n Related to Globalization
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants